# 传递列表
def greet_users(names):
    "向列表中的每位用户发送简单的问候"
    for name in names:
        msg = "hello,"+name.title()+"!"
        print(msg)
usernames = ['hannah', 'ty', 'margot']
greet_users(usernames)

# 传递任意数量的实参
def make_pizza(*toppings):
    "打印顾客的所有配料"
    print(toppings)
make_pizza('pepperoni')
make_pizza('red', 'green')

# 使用任意数量的关键字实参
def build_profile(first, last, **user_info):
    "创建一个字典，其中包含我们知道的有关用户的一切"
    profile = {}
    profile['first_name'] = first
    profile['last_name'] = last
    for key, value in user_info.items():
        profile[key] = value
    return profile
user_profile = build_profile('albert', 'einstein', location='princetion',filed='physics')
print(user_profile)



